package com.shopoo.oauth.domain.constants;

/**
 * @Date: 2022/3/17 12:42 AM
 * @Author: <a href="mailto:android_li@sina.cn">MaoYuan.Li</a>
 */
public interface AuthConstant {

    public static final String AUTHORITY_PREFIX = "ROLE_";

    public static final String AUTHORITY_CLAIM_NAME = "authorities";
    /**
     * Redis缓存权限规则key
     */
    public static final String RESOURCE_ROLES_MAP_KEY = "auth:resourceRolesMap";

    /**
     * 认证信息Http请求头
     */
    public static final String JWT_TOKEN_HEADER = "Authorization";

    /**
     * JWT令牌前缀
     */
    public static final String JWT_TOKEN_PREFIX = "bearer ";

    /**
     * 用户信息Http请求头
     */
    public static final String USER_TOKEN_HEADER = "user";
    /**
     * 用户ID
     */
    public static final String USERID = "userId";
    /**
     * 用户名
     */
    public static final String USERNAME = "username";

}
